package com.lzs.bootsafety.business.sys.mapper;

import com.lzs.bootsafety.business.sys.entity.SysRoleMenu;
import org.springframework.stereotype.Repository;

import java.util.List;
@Repository
public interface SysRoleMenuMapper {
    /**
     * 批量添加角色菜单
     * @param sysRoleMenu
     * @return
     */
    int batchInsertRoleMenu(List<SysRoleMenu> sysRoleMenu);
    /**
     * 根据角色id查询拥有的菜单权限
     * @param roleId
     * @return
     */
    List<Long> selectMenuByRoleId(Long roleId);

    /**
     *批量移除角色菜单
     * @param roleIds
     * @return
     */
    int batchRemoveRoleMenuByRoleId(Long[] roleIds);

    int deleteByPrimaryKey(Long id);

    int insert(SysRoleMenu record);

    int insertSelective(SysRoleMenu record);

    SysRoleMenu selectByPrimaryKey(Long id);

    int updateByPrimaryKeySelective(SysRoleMenu record);

    int updateByPrimaryKey(SysRoleMenu record);
}